-
-
Notifications
You must be signed in to change notification settings - Fork 980
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add wasm support #754
Add wasm support #754
Conversation
It seems when emscripten env is activated, make cannot execute cmake due to the same reason with emscripten-core/emsdk#616, so I have to put these in a separate script inside wasm/. |
如果能吧 node.js bindings 切换到 wasm 实现,那就更好了 |
add_subdirectory(test) | ||
if (NOT EMSCRIPTEN) | ||
add_subdirectory(doc) | ||
add_subdirectory(data) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
那 txt 转 ocd2 的工作如何在编译时进行?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
wasm/build.sh里,先本地编译,然后把ocd2产物共享给wasm
可行,就是wasm速度会比native慢一些,不一定划算 |
等等作者( @BYVoid )的意见吧,我只是觉得 wasm 免除编译带来的优势更大(指开箱即用) |
my opencc算是我做my rime的一个中间产物,所以用C++版opencc是个刚需 |
I am sorry but I am not familiar with wasm. You can create a separate repo for this purpose. |
做了个网站,纯前端wasm转换繁简https://my-opencc.vercel.app/ 支持全部14个json配置
代码:https://github.com/LibreService/my_opencc
想把wasm构建部分合并到上游
跟https://github.com/oyyd/wasm-opencc 的区别:
CMakeLists.txt
和;wasm-opencc的改动比较大,基本没法合并Makefile